package com.frxuexi.lib_base

import androidx.lifecycle.MutableLiveData

object LiveDataBus {
    val map = mutableMapOf<String,MutableLiveData<String>>()

    @Synchronized
    fun with(key:String):MutableLiveData<String>{
        if(!map.containsKey(key)){
            map[key]=MutableLiveData()
        }
        return map[key]!!
    }
}